//
//  HTTPClient.h
//  ZhihuDaily
//
//  Created by 梁慧聪 on 16/8/3.
//  Copyright © 2021年 梁慧聪. All rights reserved.
//

#import <Foundation/Foundation.h>

@class CLHTTPManager;
@class CLBaseResponseModel;

typedef void (^CLSuccessBlock)(NSURLSessionDataTask *task, CLBaseResponseModel *model);
typedef void (^HttpClientImageSuccessBlock)(UIImage *image, NSError *error);
typedef void (^CLFailureBlock)(NSURLSessionDataTask *task, CLBaseResponseModel *model);

@interface CLHTTPClient : NSObject

@property (nonatomic, strong, readonly) CLHTTPManager *httpManager;

SYNTHESIZE_SINGLETON_FOR_CLASS_HEADER(CLHTTPClient)

- (void)getImageWithURL:(NSURL *)url completion:(HttpClientImageSuccessBlock)completion;

@end
